<!DOCTYPE html>
<!--[if IE 8]> <html lang="en" class="ie8 no-js"> <![endif]-->
<!--[if IE 9]> <html lang="en" class="ie9 no-js"> <![endif]-->
<body class="page-header-fixed">
<div class="form-group" style="margin: 0px;" id="refundManageQueryModel">
		<div class="row">
			<label class="col-sm-1 control-label text-right" >手机号码</label>
			<div class="col-sm-3">
				<div class="input-group">
					<input class="form-control bValidate" 	key="tel" 	type="text"  ng-model="searchModel.mobileNo"/>
				 </div>
			</div> 
			<label class="col-sm-1 control-label text-right"  >开始日期</label>
			<div class="col-sm-2"> 
				<div class="input-group">
					<input class="form-control getTime bValidate" 	key="date"	type="text" ng-model="searchModel.startDate"/>
				</div>
			</div>
			<label class="col-sm-1 control-label text-right"  >结束日期</label>
			<div class="col-sm-2"> 
				<div class="input-group"> 
					<input class="form-control getTime bValidate" 	key="date"	type="text" ng-model="searchModel.endDate"/>
				</div>
			</div>
			<div class="col-sm-1">
				<div class="input-group">
					<button type="button" class="btn btn-primary"  ng-click="queryTranInfosForRefund();"  ><i class="fa "></i>查询</button>
				</div>
			</div>
		</div>
</div>

<hr />
<table class="table table-striped table-bordered table-hover"
		id="table_1">
		<thead>
			<tr>
				<th>交易流水</th>
				<th>消费卡号</th>
				<th>用户名称</th>
				<th>服务名称</th>
				<th>交易时间</th>
				<th>交易总金额</th>
				<th>企业名称</th>
				<th>操作</th>
			</tr>
		</thead>
		<tbody>
			<tr class="odd gradeX"
				ng-repeat="item in tranInfoList  track by $index"
				on-loaded="{{$last}}"  target-table="table_1">
				<td ><span	ng-bind="item.tradeNo "></span>	</td>
				<td ><span	ng-bind="item.cardNo "></span>	</td>
				<td ><span	ng-bind="item.originalPayerName"></span>	</td>
				<td ><span	ng-bind="item.serviceNo |  getValueInArgFilter : orderServiceMap : 'name' "></span>	</td>
				<td ><span	ng-bind="item.platTime | date:'yyyy-MM-dd HH:mm:ss'"></span>	</td>
				<td ><my-span  amount="item.paymentAmount " /></td>
				<td><span 	ng-bind="item.receiver  |  getValueInArgFilter : merchantMap : 'name' " ></span></td>	
				<td >
					<a class="btn" href="javascript:;"  data-target="#refundModel"		data-toggle="modal"  ng-click="queryTranSubJrnl(item);">
							退款
					</a>
				</td>
			</tr>
		</tbody>
	</table>
	
	<div id="refundModel" class="modal fade"   role="dialog" aria-hidden="true"   data-backdrop="false">
			<div class="modal-dialog"  style="width: 700px;">
				<div class="modal-header">
				<button type="button" class="close" data-dismiss="modal"	aria-hidden="true">×</button>
					<h4 class="modal-title">交易号{{selecedTranInfo.tradeNo}}退款信息</h4>
				</div>
				<div class="modal-content">
					<div class="modal-body form">
						<table class="table table-striped table-bordered table-hover  dataTable"		id="table_2">
							<thead>
								<tr>
									<th>交易子流水</th>
									<th>子服务名称</th>
									<th>合作商名称</th>
									<th>收入金额</th>
									<th>退款金额</th>
								</tr>
							</thead>
							<tbody>
								<tr class="odd gradeX" 	ng-repeat="item in subJrnlList  track by $index"	on-loaded="{{$last}}"  target-table="table_1">
									<td ><span	ng-bind="item.subTradeNo "></span>	</td>
									<td ><span	ng-bind="item.serviceNo |  getValueInArgFilter : orderServiceMap : 'name'  "></span>	</td>
									<td ><span	ng-bind="item.receiver |   getValueInArgFilter : merchantMap : 'name' "></span>	</td>
									<td ><my-span  amount="item.paymentAmount " /></td>
									<td>
											<span class="input-group">
												<input type="text" class="form-control  bValidate " id="{{item.subTradeNo}}" key="required" 
												ng-model="item.refundAmount"  ng-change="countTotalAmount(item);"/>
											</span>
									</td>	
								</tr>
							</tbody>
						</table>
						<div class="col-sm-12">
							<label class="col-sm-9 control-label text-right"  >退款总金额:<span ng-bind="taotalAmount" style="margin-left: 10px;" ></span></label>
						</div> 
						
					</div>
					<div class="modal-footer" style="border-top:0">
						<button type="button" class="btn btn-danger" data-dismiss="modal"><i class="fa fa-times"></i>关闭</button>
						<button type="button" class="btn btn-primary" ng-click="saveRefundInfo();">
						<i class="fa fa-check"></i>保存</button>
					</div>
				</div>
			</div>
		</div>
</body>
<script src="manageView/assets/scripts/public.js" type="text/javascript"></script>
</html>  